package com.ophelisis.persistence.dao.impl;

import java.sql.SQLException;
import java.util.List;
import java.util.Map;

import org.springframework.dao.DataAccessException;
import org.springframework.stereotype.Repository;

import com.ophelisis.ibatis.handler.handler_board_photo;
import com.ophelisis.persistence.dao.BoardPhotoDAO;
import com.ophelisis.persistence.domain.BoardPhotoVO;

/**
 * <pre>
 * Class : com.ophelisis.persistence.dao.impl.BoardPhotoDAOImpl / BoardPhotoDAOImpl.java
 * 	Define Class Object : 
 * <br>
 * </pre>
 * @author hwanLee / apexcns,Inc.
 * @version 1.0
 * @see javadoc
 * @since 2013. 07. 29.
 */
@Repository
public class BoardPhotoDAOImpl implements BoardPhotoDAO {
	@Override
	public List<BoardPhotoVO> getBoardPhotoList() throws DataAccessException, SQLException, Exception {
		try {
			return handler_board_photo.getBoardPhotoList();
		} catch (SQLException e) {
			e.printStackTrace();
			return null;
		}
	}

	@Override
	public List<BoardPhotoVO> getBoardPhotoList(Map<String, Object> params) throws DataAccessException, SQLException, Exception {
		try {
			return handler_board_photo.getBoardPhotoList(params);
		} catch (SQLException e) {
			e.printStackTrace();
			return null;
		}
	}

	@Override
	public Integer getBoardPhotoListCnt() throws DataAccessException, SQLException, Exception {
		try {
			return handler_board_photo.getBoardPhotoListCnt();
		} catch (SQLException e) {
			e.printStackTrace();
			return 0;
		}
	}

	@Override
	public Integer getBoardPhotoListCnt(Map<String, Object> params) throws DataAccessException, SQLException, Exception {
		try {
			return handler_board_photo.getBoardPhotoListCnt(params);
		} catch (SQLException e) {
			e.printStackTrace();
			return 0;
		}
	}
	
	@Override
	public List<BoardPhotoVO> getBoardPhotoDetail(Map<String, Object> params) throws DataAccessException, SQLException, Exception {
		try {
			return handler_board_photo.getBoardPhotoDetail(params);
		} catch (SQLException e) {
			e.printStackTrace();
			return null;
		}
	}

	@Override
	public Integer setBoardPhotoDelete(Map<String, Object> params) throws DataAccessException, SQLException, Exception {
		try {
			return handler_board_photo.setBoardPhotoDelete(params);
		} catch (SQLException e) {
			e.printStackTrace();
			return 0;
		}
	}

	@Override
	public Integer setBoardPhotoDeleteFinal(Map<String, Object> params) throws DataAccessException, SQLException, Exception {
		try {
			return handler_board_photo.setBoardPhotoDeleteFinal(params);
		} catch (SQLException e) {
			e.printStackTrace();
			return 0;
		}
	}

	@Override
	public Integer setBoardPhotoModify(BoardPhotoVO paramVO) throws DataAccessException, SQLException, Exception {
		try {
			return handler_board_photo.setBoardPhotoModify(paramVO);
		} catch (SQLException e) {
			e.printStackTrace();
			return 0;
		}
	}

	@Override
	public Integer setBoardPhotoAdd(BoardPhotoVO paramVO) throws DataAccessException, SQLException, Exception {
		try {
			return handler_board_photo.setBoardPhotoAdd(paramVO);
		} catch (SQLException e) {
			e.printStackTrace();
			return 0;
		}
	}
}
